﻿using Husb.DataUtil;
using System.Data;
namespace CentralOffice.File.Data {


    partial class FileDataSet
    {
        partial class FileRow
        {
            #region GenerateFilterExpression
            public string FilterExpression
            {
                get
                {
                    string where = "";

                    //where += DataAccessUtil.GetPartWhereCondition("Id", this);
                    where += DataAccessUtil.GetPartWhereCondition("Name", this);
                    where += DataAccessUtil.GetPartWhereCondition("Subtitle", this);
                    where += DataAccessUtil.GetPartWhereCondition("FileNumber", this);
                    where += DataAccessUtil.GetPartWhereCondition("QueryNumber", this);
                    where += DataAccessUtil.GetPartWhereCondition("Keywords", this);
                    where += DataAccessUtil.GetPartWhereCondition("Theme", this);
                    where += DataAccessUtil.GetPartWhereCondition("UrgencyPriority", this, true, true);
                    where += DataAccessUtil.GetPartWhereCondition("Publisher", this);
                    where += DataAccessUtil.GetPartWhereCondition("SecretLevel", this, true, true);
                    where += DataAccessUtil.GetPartWhereCondition("FileCategoryId", this, DbType.Guid);
                    where += DataAccessUtil.GetPartWhereCondition("Remark", this);
                    where += DataAccessUtil.GetPartWhereCondition("Attachments", this);
                    where += DataAccessUtil.GetPartWhereCondition("ArchivingTime", "ArchivingTimeEnd", this);
                    where += DataAccessUtil.GetPartWhereCondition("ArchivedBy", this);
                    where += DataAccessUtil.GetPartWhereCondition("DepositIn", this);
                    where += DataAccessUtil.GetPartWhereCondition("TaskId", this, DbType.Guid);

                    //where += DataAccessUtil.GetPartWhereCondition("IsDeleted", this);
                    //where += DataAccessUtil.GetPartWhereCondition("IsActive", this);
                    //where += DataAccessUtil.GetPartWhereCondition("CreatedTime", this);
                    //where += DataAccessUtil.GetPartWhereCondition("CreatedBy", this);
                    //where += DataAccessUtil.GetPartWhereCondition("ModifiedTime", this);
                    //where += DataAccessUtil.GetPartWhereCondition("LastModifiedBy", this);
                    //where += DataAccessUtil.GetPartWhereCondition("Version", this);
                    //where += DataAccessUtil.GetPartWhereCondition("Description", this);

                    return where;
                }
            }

            #endregion
        }
    }
}
